<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Class Details</title>
</head>
<body>
	<h1>Class Details</h1>
	<form:form id="classForm" action="class-form.html" commandName="clazz">
		<form:hidden path="id"/>
		<form:hidden path="parentComponentId"/>
		<table>
			<tr>
				<th>Name</th>
				<td><form:input path="className"/></td>
				<td>Use Camel Case, No Space and Special Characters Allowed</td>
			</tr>
			<tr>
				<th>Description</th>
				<td><form:textarea path="classDesc"/></td>
				<td></td>
			</tr>
			<tr>
				<th>Table Name</th>
				<td><form:input path="tableName"/></td>
				<td></td>
			</tr>
			<tr>
				<th>Is Auditable</th>
				<td>
					<form:radiobutton path="isAuditable" value="true"/> Yes<br/>
					<form:radiobutton path="isAuditable" value="false"/> No
				</td>
				<td></td>
			</tr>
			<tr>
				<th>Is Versionable</th>
				<td>
					<form:radiobutton path="isVersionable" value="true"/> Yes<br/>
					<form:radiobutton path="isVersionable" value="false"/> No
				</td>
				<td></td>
			</tr>
			<tr>
				<th>Is Soft Deletable</th>
				<td>
					<form:radiobutton path="isSoftDeletable" value="true"/> Yes<br/>
					<form:radiobutton path="isSoftDeletable" value="false"/> No
				</td>
				<td></td>
			</tr>
		</table>
		<input type="button" value="Cancel" onclick="javascript:location.href='class-list.html?method=list&parentComponentId=<c:out value="${clazz.parentComponentId}"/>'"/>
		<input type="submit" value="Save"/>
	</form:form>
</body>
</html>